



		****************************************************************
		* This File Loads the Data from Excel and Labels the Variables *
		****************************************************************
		
		
		* Import Scenario Data
		import excel "data/final_data_scenarios.xlsx", sheet("Sheet1") firstrow clear
		rename respid id
		save "data/final_data_scenarios.dta", replace
		
		
		* Import Final Data
		import excel "data/finaldata_varnames.xlsx", sheet("Sheet1") firstrow clear

		* Rename variables used in Scenarios
		
		rename ValueXHIDDENVALUEOFX ValueX
		rename ValueYxQ42HIDDENVALUEOFY ValueYQ42
		rename ValueYxQ45HIDDENVALUEOFY ValueYQ45
		rename ValueIHIDDENVALUEOFI ValueI
		rename ValueSIHIDDENVALUEOFSI ValueSI
		rename ValueRIHIDDENVALUEOFRI ValueRI
		rename ValueSRIHIDDENVALUEOFSRI ValueSRI
		rename ValueHHSHIDDENVALUEOFHHS ValueHHS
		rename ValueHHRSHIDDENVALUEOFHH ValueHHRS
		rename ValueGIS_1Q42ANDQ45HIDDEN ValueGIS_1
		rename ValueGIS_2Q43ANDQ46HIDDEN ValueGIS_2
		rename ValueGIS_3Q44ANDQ47HIDDEN ValueGIS_3
		rename ValueOAS_1Q42ANDQ45HIDDEN ValueOAS_1
		rename ValueOAS_2Q43ANDQ46HIDDEN ValueOAS_2
		rename ValueOAS_3Q44ANDQ47HIDDEN ValueOAS_3

		*Rename, recode and add labels
		rename respi id

		rename lPleaseselectyourpreferred language
		recode language (9=0) (3084=1)

		label var language "Interview language"
		label def language 0 "English" 1 "French"
		label val language language

		rename VERSIONVERSION version
		label var version "Version of the survey"
		label def version 1 "Soft launch"
		label val version version

		rename QAAreyou male
		destring male, replace
		recode male (2=0)
		label var male "QA : Respondent is male"
		label def male 0"Female" 1 "Male"
		label val male male

		rename QBHowoldareyouPleasespe age
		label var age "QB : Respondent age"

		rename QCWhichprovinceorterritory province
		destring province, replace
		recode province (5=0) (6=1)
		label var province "QC : province of residence"
		label def province 0 "Ontario" 1 "Quebec"
		label val province province

		rename Q0Whatisthehighestcertifi educ
		destring educ, replace
		label var educ "Q0 : highest education level of respondent"
		label def educ 1 "Less HS" 2 "HS" 3 "Trade certificate" 4 "College" 5 "University below B.Sc." 6 "B.Sc." 7 "M.Sc +" 
		label val educ educ

		rename Q1Whatisyourmaritalstatus marstat
		destring marstat , replace
		label var marstat "Q1 : marital status of respondent"
		label def marstat 1 "Married" 2 "Common-law" 3 "Widowed" 4 "Separated" 5 "Divorced" 6 "Never married"
		label val marstat marstat

		rename Q1aHowoldisyourpartner age_sp
		label var age_sp "Q1a : Spouse's age"

		rename Q2Whichofthefollowingstat workstatus
		destring workstatus, replace
		recode workstatus (5=4) (7777777=7) (8888888=8)
		label var workstatus "Q2 : Respondent's work situation" 
		label def workstatus 1 "Employed" 2 "Self-employed" 3 "Unpaid -family business" 4 "Did not work" 7 "DK" 8 "R"
		label val workstatus workstatus

		rename Q3For2017whatisyourbest totinc
		label var totinc "Q3 : Respondent total income in 2017"

		rename Q3aIsitmorethan60000 totinc_gt_60k
		rename Q3bIsitlessthan80000 totinc_lt_80k
		rename Q3cIsitmorethan100000 totinc_gt_100k
		rename Q3dIsitmorethan40000 totinc_gt_40k
		rename Q3eIsitmorethan20000 totinc_gt_20k


		label var totinc_gt_60k "Q3a : Respondent total income in 2017 is greater than 60K"
		label var totinc_lt_80k "Q3b : Respondent total income in 2017 is less than 80K"
		label var totinc_gt_100k "Q3c : Respondent total income in 2017 is greater than 100K"
		label var totinc_gt_40k "Q3d : Respondent total income in 2017 is greater than 40K"
		label var totinc_gt_20k "Q3e : Respondent total income in 2017 is greater than 20K"


		rename Q4For2017whatisyourbest totinc_sp
		label var totinc "Q4 : Spouse's total income in 2017"


		rename Q4aIsitmorethan60000 totinc_sp_gt_60k
		rename Q4bIsitlessthan80000 totinc_sp_lt_80k
		rename Q4cIsitmorethan100000 totinc_sp_gt_100k
		rename Q4dIsitmorethan40000 totinc_sp_gt_40k
		rename Q4eIsitmorethan20000 totinc_sp_gt_20k

		label var totinc_sp_gt_60k "Q4a : Spouse total income in 2017 is greater than 60K"
		label var totinc_sp_lt_80k "Q4b : Spouse total income in 2017 is less than 80K"
		label var totinc_sp_gt_100k "Q4c : Spouse total income in 2017 is greater than 100K"
		label var totinc_sp_gt_40k "Q4d : Spouse total income in 2017 is greater than 40K"
		label var totinc_sp_gt_20k "Q4e : Spouse total income in 2017 is greater than 20K"


		rename Q5For2017whatisyourbest spend
		label var spend "Q5 : Monthly spending in 2017"

		rename Q5aIsitmorethan9000 spend_gt_9k
		rename Q5bIsitlessthan13000 spend_lt_13k
		rename Q5cIsitmorethan11000 spend_gt_11k
		rename Q5dIsitmorethan15000 spend_gt_15k
		rename Q5eIsitlessthan17000  spend_lt_17k
		rename Q5fIsitmorethan5000 spend_gt_5k
		rename Q5gIsitlessthan7000 spend_lt_7k
		rename Q5hIsitlessthan3000 spend_lt_3k
		rename Q5iIsitmorethan1000 spend_gt_1k


		label var spend_gt_9k "Q5a : monthly spending in 2017 is greater than 9k"
		label var spend_lt_13k "Q5b : monthly spending in 2017 is less than 13k"
		label var spend_gt_11k "Q5c : monthly spending in 2017 is greater than 11k"
		label var spend_gt_15k "Q5d : monthly spending in 2017 is greater than 15k"
		label var spend_lt_17k "Q5e : monthly spending in 2017 is less than 17k"
		label var spend_gt_5k "Q5f : monthly spending in 2017 is greater than 5k"
		label var spend_lt_7k "Q5g : monthly spending in 2017 is less than 7k"
		label var spend_lt_3k "Q5h : monthly spending in 2017 is less than 3k"
		label var spend_gt_1k "Q5i : monthly spending in 2017 is greater than 1k"

		#delimit ;
		foreach var of varlist totinc_gt_60k totinc_lt_80k  totinc_gt_100k totinc_gt_40k totinc_gt_20k 
		totinc_sp_gt_60k totinc_sp_lt_80k  totinc_sp_gt_100k totinc_sp_gt_40k totinc_sp_gt_20
		spend_gt_9k spend_lt_13k spend_gt_11k spend_gt_15k spend_lt_17k spend_gt_5k spend_lt_7k spend_gt_1k spend_lt_3k {;
			destring `var', replace;
			recode `var' (1=1) (2=0) (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr


		rename Q6Doyouownyourprimaryres own_house
		destring own_house, replace
		label var own_house " Q6 : Respondent owns primary residence"
		recode own_house (7777777 =7) (8888888=8) (2=0)
		label def own_house  1 "Yes" 0 "No" 7 "DK" 8 "R"
		label val own_house own_house

		rename Q7Whatisthecurrentmarket marktval_house
		label var marktval_house "Q7 : House's market value "

		rename Q7aIsitmorethan300000 marktval_house_gt300k
		rename Q7bIsitlessthan600000 marktval_house_lt600k
		rename Q7cIsitmorethan450000 marktval_house_gt450k
		rename Q7dIsitlessthan750000 marktval_house_lt750k
		rename Q7eIsitmorethan900000 marktval_house_gt900k
		rename Q7fIsitmorethan150000 marktval_house_gt150k


		label var marktval_house_gt300k "Q7a : House's market value is greater than 300k"
		label var marktval_house_lt600k "Q7b : House's market value is less than 600k"
		label var marktval_house_gt450k "Q7c : House's market value is greater than 450k"
		label var marktval_house_lt750k "Q7d : House's market value is less than 750k"
		label var marktval_house_gt900k "Q7e : House's market value is greater than 900k"
		label var marktval_house_gt150k "Q7f : House's market value is greater than 150k"


		#delimit ;
		foreach var of varlist marktval_house_gt300k marktval_house_lt600k marktval_house_gt450k marktval_house_lt750k 
		marktval_house_gt900k marktval_house_gt150k{;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8) (2=0) ;
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q8_1IndividualRRSPsRegiste ind_rrsp
		rename Q8_2IndividualTFSAsTaxFre ind_tfsa
		rename Q8_3RESPsRegisteredEducati ind_resp
		rename Q8_4Savingsaccountsornonr ind_savings
		rename Q8_5Universallifeinsurance ind_lifeins
		rename Q8_6Otherassetscarsecond ind_other
		rename Q8_7Idontownanyofthepr ind_noasset
		rename Q8_7777777DontknowAmongt ind_dk
		rename Q8_8888888Refusetoanswer ind_r

		label var ind_rrsp "Q8_1 : Respondent has personal RRSPs"
		label var ind_tfsa "Q8_2 : Respondent has personal TFSAs"
		label var ind_resp "Q8_3 : Respondent has personal RESPs"
		label var ind_savings "Q8_4 : Respondent has personal savings"
		label var ind_lifeins "Q8_5 : Respondent has personal life insurance"
		label var ind_other "Q8_6 : Respondent has other personal assets"
		label var ind_noasset "Q8_7 : Respondent does not have personal assets"
		label var ind_dk "Q8_DK : Respondent DK for question on personal assets"
		label var ind_r "Q8_R : Respondent R for question on personal assets"

		#delimit ;
		foreach var of varlist ind_rrsp ind_tfsa ind_resp ind_savings ind_lifeins ind_noasset ind_other ind_dk ind_r {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q9_1RRSPsWhatisyourbest ind_rrsp_amt
		rename Q9a_1RRSPsIsitmorethan ind_rrsp_amt_gt50k
		rename Q9b_1RRSPsIsitlessthan ind_rrsp_amt_lt200k
		rename Q9c_1RRSPsIsitmorethan ind_rrsp_amt_gt10k
		rename Q9_2TFSAsWhatisyourbest ind_tfsa_amt
		rename Q9a_2TFSAsIsitmorethan ind_tfsa_amt_gt50k
		rename Q9b_2TFSAsIsitlessthan ind_tfsa_amt_lt200k
		rename Q9c_2TFSAsIsitmorethan ind_tfsa_amt_gt10k
		rename Q9_4Savingsaccountsornon ind_savings_amt
		rename  Q9a_4Savingsaccountsornon ind_savings_amt_gt50k
		rename Q9b_4Savingsaccountsornon ind_savings_amt_lt200k
		rename Q9c_4Savingsaccountsornon ind_savings_amt_gt10k


		foreach name in "rrsp" "tfsa" "savings" {


		label var ind_`name'_amt "Q9 : Accumulated amount in personnal `name'"
		label var ind_`name'_amt_gt50k "Q9a : Accumulated amount in personnal `name' is greater than 50k"
		label var ind_`name'_amt_lt200k "Q9b : Accumulated amount in personnal `name' is less than 200k"
		label var ind_`name'_amt_gt10k "Q9c : Accumulated amount in personnal `name' is greater than 10k"

		}

		#delimit ;
		foreach var of varlist ind_rrsp_amt_gt50k ind_rrsp_amt_lt200k ind_rrsp_amt_gt10k  ind_tfsa_amt_gt50k
		ind_tfsa_amt_lt200k ind_tfsa_amt_gt10k ind_savings_amt_gt50k ind_savings_amt_lt200k ind_savings_amt_gt10k {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 2 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q10_1_1Q10_1RRSPsWhatis ind_rrsp_stock
		rename Q10a_1RRSPsIsitmorethan ind_rrsp_stock_gt50
		rename Q10b_1RRSPsIsitlessthan ind_rrsp_stock_lt75
		rename Q10c_1RRSPsIsitlessthan ind_rrsp_stock_lt25
		rename Q10_1_2Q10_1TFSAsWhatis ind_tfsa_stock
		rename Q10a_2TFSAsIsitmorethan ind_tfsa_stock_gt50
		rename Q10b_2TFSAsIsitlessthan ind_tfsa_stock_lt75
		rename Q10c_2TFSAsIsitlessthan ind_tfsa_stock_lt25
		rename Q10_1_4Q10_1Savingsaccoun ind_savings_stock
		rename Q10a_4Savingsaccountsorno ind_savings_stock_gt50
		rename Q10b_4Savingsaccountsorno ind_savings_stock_lt75
		rename Q10c_4Savingsaccountsorno ind_savings_stock_lt25


		foreach name in "rrsp" "tfsa" "savings" {


		label var ind_`name'_stock "Q10 : Percentage of amount in personnal `name' invested stocks"
		label var ind_`name'_stock_gt50 "Q10a : Percentage of amount in personnal `name' invested stocks greater than 50%"
		label var ind_`name'_stock_lt75 "Q10b : Percentage of amount in personnal `name' invested stocks less than 75%"
		label var ind_`name'_stock_lt25 "Q10c : Percentage of amount in personnal `name' invested stocks less than 25%"

		}


		#delimit ;
		foreach var of varlist ind_rrsp_stock ind_rrsp_stock_gt50 ind_rrsp_stock_lt75 
		ind_rrsp_stock_lt25 ind_tfsa_stock ind_tfsa_stock_gt50 ind_tfsa_stock_lt75 ind_tfsa_stock_lt25
		 ind_savings_stock ind_savings_stock_gt50 ind_savings_stock_lt75 ind_savings_stock_lt25 {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr



		rename Q11Doyouhaveafinancialad advisor
		destring advisor, replace
		label var advisor " Q6 : Respondent has a financial advisor"
		recode advisor (7777777 =7) (8888888=8) (2=0)
		label def advisor  1 "Yes" 0 "No" 7 "DK" 8 "R"
		label val advisor advisor


		rename Q11aC1_1Commissionontrad advisor_pct_com_rrsp
		rename Q11aC1_2Commissionontrad advisor_amt_com_rrsp
		rename Q11aC1_3Feeforservicepe advisor_amt_yffs_rrsp
		rename Q11aC1_4Feeforservicepe advisor_amt_hffs_rrsp
		rename Q11aC1_5Feeforserviceof advisor_pct_yffs_rrsp
		rename Q11aC1_6Myfinancialinstitut advidor_instit_rrsp
		rename Q11aC1_7Myfinancialadvisor advidor_not_rrsp
		rename Q11aC1_7777777DontknowMai advidor_dk_rrsp
		rename Q11aC1_8888888Refusetoanswe advidor_r_rrsp
		 
		rename Q11aC2_1Commissionontrad advisor_pct_com_tfsa
		rename Q11aC2_2Commissionontrad advisor_amt_com_tfsa
		rename Q11aC2_3Feeforservicepe advisor_amt_yffs_tfsa
		rename Q11aC2_4Feeforservicepe advisor_amt_hffs_tfsa
		rename Q11aC2_5Feeforserviceof advisor_pct_yffs_tfsa
		rename Q11aC2_6Myfinancialinstitut advidor_instit_tfsa
		rename Q11aC2_7Myfinancialadvisor advidor_not_tfsa
		rename Q11aC2_7777777DontknowMai advidor_dk_tfsa
		rename Q11aC2_8888888Refusetoanswe advidor_r_tfsa

		rename Q11aC4_1Commissionontrad  advisor_pct_com_savings
		rename Q11aC4_2Commissionontrad advisor_amt_com_savings
		rename Q11aC4_3Feeforservicepe advisor_amt_yffs_savings
		rename Q11aC4_4Feeforservicepe  advisor_amt_hffs_savings
		rename Q11aC4_5Feeforserviceof advisor_pct_yffs_savings
		rename Q11aC4_6Myfinancialinstitut advidor_instit_savings
		rename Q11aC4_7Myfinancialadvisor advidor_not_savings 
		rename Q11aC4_7777777DontknowMai advidor_dk_savings
		rename Q11aC4_8888888Refusetoanswe advidor_r_savings

		foreach name in "rrsp" "tfsa" "savings" {
		label var advisor_pct_com_`name'  "Q11a : Advisor is paid by commisions (%) for `name'"
		label var advisor_amt_com_`name' "Q11a : Advisor is paid by commisions ($) for `name'"
		label var advisor_amt_yffs_`name' "Q11a : Advisor is paid by yearly FFS ($) for `name'"
		label var advisor_amt_hffs_`name' "Q11a : Advisor is paid by hourly FFS ($) for `name'"
		label var advisor_pct_yffs_`name' "Q11a : Advisor is paid by yearly FFS (%) for `name'"
		label var advidor_instit_`name'  "Q11a : Advisor is paid by financial institution for `name'"
		label var advidor_not_`name'  "Q11a : Advisor does not manage `name'"
		label var advidor_dk_`name' "Q11a : Don't know how advisor is paid for `name'"
		label var advidor_r_`name' "Q11a : Refuse to answer how advisor is paid for `name'"


		}


		#delimit ;
		foreach var of varlist advisor_pct_com_rrsp advisor_amt_com_rrsp advisor_amt_yffs_rrsp advisor_amt_hffs_rrsp 
		advisor_pct_yffs_rrsp advidor_instit_rrsp advidor_not_rrsp advidor_dk_rrsp advidor_r_rrsp advisor_pct_com_tfsa 
		advisor_amt_com_tfsa advisor_amt_yffs_tfsa advisor_amt_hffs_tfsa advisor_pct_yffs_tfsa advidor_instit_tfsa 
		advidor_not_tfsa advidor_dk_tfsa advidor_r_tfsa advisor_pct_com_savings advisor_amt_com_savings
		 advisor_amt_yffs_savings advisor_amt_hffs_savings advisor_pct_yffs_savings advidor_instit_savings
		 advidor_not_savings advidor_dk_savings advidor_r_savings {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr



		rename Q11bIsyourfinancialadvisor advisor_bank
		destring advisor_bank, replace
		label var advisor_bank "Q11b : Financial advisor in tied to financial institution"
		recode advisor_bank (7777777 =7) (8888888=8) (2=0)
		label def advisor_bank  1 "Yes" 0 "No" 7 "DK" 8 "R"
		label val advisor_bank advisor_bank



		rename Q11c_1Ialreadyhadafinanci advisor_bankNo_already
		rename Q11c_2Myfinancialinstitutio advisor_bankNo_advice
		rename Q11c_3Ipreferdealingwitha advisor_bankNo_indepen
		rename Q11c_4Myfinancialadvisoris advisor_bankNo_family
		rename Q11c_5ItislessexpensiveW advisor_bankNo_cost
		rename Q11c_6OtherspecifyWhySe advisor_bankNo_other
		rename Q11c_6_otherOtherspecifyW advisor_bankNo_other_spec
		rename Q11c_7777777DontknowWhy advisor_bankNo_dk
		rename Q11c_8888888Refusetoanswer advisor_bankNo_r

		rename Q11d_1Ihaveenoughfinancial no_advisor_knowl
		rename Q11d_2Theservicesofafinan no_advisor_cost
		rename Q11d_3Idonothaveenoughmo no_advisor_money
		rename Q11d_4Idonottrustfinancia no_advisor_trust
		rename Q11d_5Arelativedealswithm no_advisor_family
		rename Q11d_6OtherspecifyWhySe  no_advisor_other
		rename  Q11d_6_otherOtherspecifyW no_advisor_other_spec
		rename Q11d_7777777DontknowWhy no_advisor_dk
		rename Q11d_8888888Refusetoanswer no_advisor_r
		 


		label var advisor_bankNo_already "Q11c : Financial advisor not tied to insitution - already have one"
		label var advisor_bankNo_advice "Q11c : Financial advisor not tied to insitution - wrong types of advice"
		label var advisor_bankNo_indepen "Q11c : Financial advisor not tied to insitution - have independent one"
		label var advisor_bankNo_family "Q11c : Financial advisor not tied to insitution - have one that was recommended"
		label var advisor_bankNo_cost "Q11c : Financial advisor not tied to insitution - less expensive"
		label var advisor_bankNo_other "Q11c : Financial advisor not tied to insitution - other"
		label var advisor_bankNo_other_spec "Q11c : Financial advisor not tied to insitution - other reason given"
		label var advisor_bankNo_dk "Q11c : Financial advisor not tied to insitution - DK"
		label var advisor_bankNo_r "Q11c : Financial advisor not tied to insitution - R"

		label var no_advisor_knowl "Q11d : No financial advisor - enough knowledge"
		label var no_advisor_cost "Q11d : No financial advisor - too expensive"
		label var no_advisor_money "Q11d : No financial advisor - not enough money"
		label var no_advisor_trust "Q11d : No financial advisor - do not trust"
		label var no_advisor_family "Q11d : No financial advisor -  relative help me"
		label var no_advisor_other "Q11d : No financial advisor - other"
		label var no_advisor_other_spec "Q11d : No financial advisor - other reason given"
		label var no_advisor_dk "Q11d : No financial advisor - DK"
		label var no_advisor_r "Q11d : No financial advisor - R"
		 

		#delimit ;
		foreach var of varlist advisor_bankNo_already advisor_bankNo_advice advisor_bankNo_indepen
		advisor_bankNo_family advisor_bankNo_cost advisor_bankNo_other advisor_bankNo_dk advisor_bankNo_r
		no_advisor_knowl no_advisor_cost no_advisor_money no_advisor_trust no_advisor_family no_advisor_other
		no_advisor_dk no_advisor_r {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q12_1DefinedbenefitDBpen emp_db
		rename Q12_2DefinedcontributionDC emp_dc
		rename Q12_3HybridpensionplanThi emp_hybrid
		rename Q12_4GroupRRSPRegisteredR emp_rrsp
		rename Q12_5GroupTFSATaxFreeSav emp_tfsa
		rename Q12_6VoluntaryRetirementSav emp_vrsp
		rename Q12_7Ichosenottoparticipa emp_optout
		rename Q12_8Myemployerdoesnotoff emp_noplan
		rename Q12_8888888Refusetoanswer emp_dk
		rename Q12_7777777DontknowAmong emp_r

		label var emp_db "Q12 : Respondent has defined benefit pension plan from employer"
		label var emp_dc "Q12 : Respondent has defined contribution pension plan from employer"
		label var emp_hybrid "Q12 : Respondent has hybrid pension plan from employer"
		label var emp_rrsp "Q12 : Respondent has group RRSP from employer"
		label var emp_tfsa "Q12 : Respondent has group TFSA from employer"
		label var emp_vrsp "Q12 : Respondent has VRSP from employer"
		label var emp_optout "Q12 : Respondent opted out of at least one employer plan"
		label var emp_noplan "Q12 : Respondent's employer does not offer a plan" 
		label var emp_dk "Q12 : DK to question on employer plans" 
		label var emp_r "Q12 : R to question on employer plans" 


		rename Q13Inyourcurrentemployment optout_vrsp
		label var optout_vrsp "Q13 : Respondent chose to opt out of VRSP/PRPP current employment"
		destring optout_vrsp, replace
		recode optout_vrsp (2=0) (7777777 =7) (8888888=8)
		label def optout_vrsp  1 "Yes" 0 "No" 7 "DK" 8 "R"
		label val optout_vrsp optout_vrsp

		rename Q13a_1Idonotwishtosavem optout_vrsp_refusetosave
		rename Q13a_2Isaveenoughmoneyels optout_vrsp_saveenough
		rename Q13a_3Ihavenotbeenworking optout_vrsp_toorecent
		rename Q13a_4Idonotplanonworkin optout_vrsp_willquit
		rename Q13a_5Iamnotabletosavem optout_vrsp_cannotsave
		rename Q13a_6Idonotunderstandthe optout_vrsp_unclear
		rename Q13a_7Theemployerprovidedp optout_vrsp_notsuited
		rename Q13a_8Otherreasonspecify optout_vrsp_other
		rename Q13a_7777777DontknowWhy optout_vrsp_dk
		rename Q13a_8888888Refusetoanswer optout_vrsp_r
		rename Q13a_8_otherOtherreasonspe optout_vrsp_other_spec

		label var optout_vrsp_refusetosave "Q13a : opted of VRSP/PRPP - do not wish to save"
		label var optout_vrsp_saveenough "Q13a : opted of VRSP/PRPP - save enough elsewhere"
		label var optout_vrsp_toorecent "Q13a : opted of VRSP/PRPP - have not been working for employed long enough"
		label var optout_vrsp_willquit "Q13a : opted of VRSP/PRPP - will quit employement soon"
		label var optout_vrsp_cannotsave "Q13a : opted of VRSP/PRPP - am not able to save money"
		label var optout_vrsp_unclear "Q13a : opted of VRSP/PRPP - do not understand the VRSP/PRPP"
		label var optout_vrsp_notsuited "Q13a : opted of VRSP/PRPP - VRSP/PRPP does not correspond to my needs"
		label var optout_vrsp_other "Q13a : opted of VRSP/PRPP - other"
		label var optout_vrsp_dk "Q13a : opted of VRSP/PRPP - DK"
		label var optout_vrsp_r "Q13a : opted of VRSP/PRPP - R"
		label var optout_vrsp_other_spec "Q13a : opted of VRSP/PRPP - other specified"

		rename Q14AnyhShowQ14set1 past_emp
		label var past_emp " Q14 : respondent participated in pension plan of previous employer"

		rename Q14a_1Definedbenefitpension past_emp_db
		rename Q14a_2Definedcontributionpe past_emp_dc
		rename Q14a_3HybridpensionplansA past_emp_hybrid
		rename Q14a_4GroupRRSPsRegistered past_emp_rrsp
		rename Q14a_5GroupTFSAsTaxFreeS past_emp_tfsa
		rename Q14a_6VoluntaryRetirementSa past_emp_vrsp
		rename Q14a_7777777DontknowAmong past_emp_dk
		rename Q14a_8888888Refusetoanswer past_emp_r

		#delimit ;
		foreach var of varlist *emp_db *emp_dc *emp_hybrid *emp_rrsp *emp_tfsa *emp_vrsp *emp_dk *emp_r emp_optout emp_noplan
		 optout_vrsp_refusetosave optout_vrsp_saveenough optout_vrsp_toorecent optout_vrsp_willquit
		optout_vrsp_cannotsave optout_vrsp_unclear optout_vrsp_notsuited optout_vrsp_other optout_vrsp_dk 
		optout_vrsp_r past_emp {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr


		rename Q15_1Q15_1Previouslyyoum mortgage
		label var mortgage "Q15 : proportion of house still owe on mortgage"

		rename Q15aItismorethan50 mortage_gt50
		rename Q15bIsitlessthan75 mortage_lt75
		rename Q15cIsitlessthan25 mortage_lt25

		label var mortage_gt50 "Q15a : owes more than 50% of house value on mortgage"
		label var mortage_lt75 "Q15b : owes less than 70% of house value on mortgage"
		label var mortage_lt25 "Q15c : owes less than 25% of house value on mortgage"

		rename Q16_1Q16_1Forthe2017fisc rrsp_2017
		label var rrsp_2017 "Q16 : Amount contributed to RRSPs for 2017 fiscal year"

		rename Q16aIsitmorethan12000 rrsp_2017_gt12k
		rename Q16bIsitlessthan18000 rrsp_2017_lt18k
		rename Q16cIsitmorethan15000 rrsp_2017_gt15k
		rename Q16dIsitmorethan21000 rrsp_2017_gt21k
		rename Q16eIsitlessthan6000 rrsp_2017_lt6k
		rename Q16fIsitmorethan3000 rrsp_2017_gt3k
		rename Q16gIsitmorethan9000 rrsp_2017_gt9k

		label var rrsp_2017_gt12k "Q16a : Amount contributed to RRSP for 2017 fiscal year greater than 12k"
		label var rrsp_2017_lt18k "Q16b : Amount contributed to RRSP for 2017 fiscal year less than 18k"
		label var rrsp_2017_gt15k "Q16c : Amount contributed to RRSP for 2017 fiscal year greater than 15k"
		label var rrsp_2017_gt21k "Q16d : Amount contributed to RRSP for 2017 fiscal year greater than 21k"
		label var rrsp_2017_lt6k "Q16e : Amount contributed to RRSP for 2017 fiscal year less than 6k"
		label var rrsp_2017_gt3k "Q16f : Amount contributed to RRSP for 2017 fiscal year greater than 3k"
		label var rrsp_2017_gt9k "Q16g : Amount contributed to RRSP for 2017 fiscal year greater than 9k"


		#delimit ;
		foreach var of varlist mortage_gt50 mortage_lt75 mortage_lt25  rrsp_2017_gt12k rrsp_2017_lt18k
		rrsp_2017_gt15k rrsp_2017_gt21k  rrsp_2017_lt6k rrsp_2017_gt3k rrsp_2017_gt9k {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8) (2=0);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q16h_1January2017Duringwh rrsp_jan2017
		rename Q16h_2February2017Duringw rrsp_feb2017
		rename Q16h_3March2017Duringwhic rrsp_mar2017
		rename Q16h_4April2017Duringwhic rrsp_apr2017
		rename Q16h_5May2017Duringwhich rrsp_may2017
		rename Q16h_6June2017Duringwhich rrsp_jun2017
		rename Q16h_7July2017Duringwhich rrsp_jul2017
		rename Q16h_8August2017Duringwhi rrsp_aug2017
		rename Q16h_9September2017During rrsp_sep2017
		rename Q16h_10October2017Duringw rrsp_oct2017
		rename Q16h_11November2017During rrsp_nov2017
		rename Q16h_12December2017During rrsp_dec2017
		rename Q16h_13January2018Duringw rrsp_jan2018
		rename Q16h_14February2018During rrsp_feb2018
		rename Q16h_7777777DontknowDurin rrsp_month_dk
		rename Q16h_8888888Refusetoanswer rrsp_month_r


		foreach name in "jan2017" "feb2017" "mar2017" "apr2017" "may2017" "jun2017" "jul2017" "aug2017" "sep2017" "oct2017" "nov2017" "dec2017" "jan2018" "feb2018" "month_dk" "month_r" {

		label var rrsp_`name' "Q16h : Contributed to RRSP in month :  `name'"
		destring rrsp_`name', replace
		recode rrsp_`name' (7777777 =7) (8888888=8) 
		label def rrsp_`name'  1 "Yes" 0 "No" 7 "DK" 8 "R"
		label val rrsp_`name' rrsp_`name'

		}


		rename Q17_1Q17_1Whatwasyourava rrsp_rights 
		label var rrsp_rights "Q17 : RRSP contribution rights for 2017"
		label def rrsp_rights 9999999 "DK/R"
		label val rrsp_rights rrsp_rights


		rename Q18_1Q18_1In2017howmuch tfsa_2017
		label var tfsa_2017 "Q18 : Amount contributed to TFSAs for 2017 fiscal year"

		rename Q18aIsitmorethan12000 tfsa_2017_gt12k
		rename Q18bIsitlessthan18000 tfsa_2017_lt18k
		rename Q18cIsitmorethan15000 tfsa_2017_gt15k
		rename Q18dIsitmorethan21000 tfsa_2017_gt21k
		rename Q18eIsitlessthan6000 tfsa_2017_lt6k
		rename Q18fIsitmorethan3000 tfsa_2017_gt3k
		rename Q18gIsitmorethan9000 tfsa_2017_gt9k

		label var tfsa_2017_gt12k "Q18a : Amount contributed to TFSA for 2017 fiscal year greater than 12k"
		label var tfsa_2017_lt18k "Q19b : Amount contributed to TFSA for 2017 fiscal year less than 18k"
		label var tfsa_2017_gt15k "Q18c : Amount contributed to TFSA for 2017 fiscal year greater than 15k"
		label var tfsa_2017_gt21k "Q18d : Amount contributed to TFSA for 2017 fiscal year greater than 21k"
		label var tfsa_2017_lt6k "Q18e : Amount contributed to TFSA for 2017 fiscal year less than 6k"
		label var tfsa_2017_gt3k "Q18f : Amount contributed to TFSA for 2017 fiscal year greater than 3k"
		label var tfsa_2017_gt9k "Q18g : Amount contributed to TFSA for 2017 fiscal year greater than 9k"



		#delimit ;
		foreach var of varlist tfsa_2017_gt12k tfsa_2017_lt18k
		tfsa_2017_gt15k tfsa_2017_gt21k  tfsa_2017_lt6k tfsa_2017_gt3k tfsa_2017_gt9k {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8) (2=0);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q19For2017didyoureachyo max_tfsa 
		label var max_tfsa " Q19 : Respondent reached contribution max TFSA for 2017"
		destring max_tfsa, replace
		recode max_tfsa (7777777 =7) (8888888=8) (2=0)
		label def max_tfsa 1 "Yes" 0 "No" 7 "DK" 8 "R"
		label val max_tfsa max_tfsa

		rename Q20_1Itismorefiscallybene rrsp_gt_tfsa_st
		rename Q20_2Itwillbemorefiscally rrsp_gt_tfsa_lt
		rename Q20_3RRSPsoffermoreflexibi rrsp_gt_tfsa_flex
		rename Q20_4SoasnottoexceedmyT rrsp_gt_tfsa_limit
		rename Q20_5Itwassuggestedbymyf rrsp_gt_tfsa_advisor
		rename Q20_6Toreimbursemoneywithd rrsp_gt_tfsa_hbp
		rename Q20_7Itwassuggestedbysome rrsp_gt_tfsa_family
		rename Q20_8OtherenterWhydidy rrsp_gt_tfsa_other
		rename Q20_7777777DontknowWhydi rrsp_gt_tfsa_dk
		rename Q20_8888888Refusetoanswer rrsp_gt_tfsa_r
		rename Q20_8_otherOtherenterWhy rrsp_gt_tfsa_other_spec

		label var rrsp_gt_tfsa_st "Q20 : contributed more to RRSP - better short term"
		label var rrsp_gt_tfsa_lt "Q20 : contributed more to RRSP - better long term"
		label var rrsp_gt_tfsa_flex "Q20 : contributed more to RRSP - more flexible"
		label var rrsp_gt_tfsa_limit "Q20 : contributed more to RRSP - to not exceed TFSA room"
		label var rrsp_gt_tfsa_advisor "Q20 : contributed more to RRSP - advisor suggested it"
		label var rrsp_gt_tfsa_hbp "Q20 : contributed more to RRSP - Reimburse HBP/LLP"
		label var rrsp_gt_tfsa_family "Q20 : contributed more to RRSP - someone close to me suggested it"
		label var rrsp_gt_tfsa_other "Q20 : contributed more to RRSP - other"
		label var rrsp_gt_tfsa_dk "Q20 : contributed more to RRSP - DK"
		label var rrsp_gt_tfsa_r "Q20 : contributed more to RRSP - R"
		label var rrsp_gt_tfsa_other_spec "Q20 : contributed more to RRSP - other specified"


		rename Q21_1Itismorefiscallybene tfsa_gt_rrsp_st
		rename Q21_2Itwillbemorefiscally  tfsa_gt_rrsp_lt
		rename Q21_3TFSAsoffermoreflexibi tfsa_gt_rrsp_flex
		rename Q21_4SoasnottoexceedmyR tfsa_gt_rrsp_limit
		rename Q21_5Itwassuggestedbymyf tfsa_gt_rrsp_advisor
		rename Q21_6Itwassuggestedbysome  tfsa_gt_rrsp_family
		rename Q21_7OtherenterWhydidy tfsa_gt_rrsp_other 
		rename Q21_7777777DontknowWhydi tfsa_gt_rrsp_dk
		rename Q21_8888888Refusetoanswer tfsa_gt_rrsp_r
		rename Q21_7_otherOtherenterWhy tfsa_gt_rrsp_other_spec

		label var tfsa_gt_rrsp_st "Q20 : contributed more to TFSA - better short term"
		label var tfsa_gt_rrsp_lt "Q20 : contributed more to TFSA - better long term"
		label var tfsa_gt_rrsp_flex "Q20 : contributed more to TFSA - more flexible"
		label var tfsa_gt_rrsp_limit "Q20 : contributed more to TFSA - to not exceed RRSP room"
		label var tfsa_gt_rrsp_advisor "Q20 : contributed more to TFSA - advisor suggested it"
		label var tfsa_gt_rrsp_family "Q20 : contributed more to TFSA - someone close to me suggested it"
		label var tfsa_gt_rrsp_other "Q20 : contributed more to TFSA - other"
		label var tfsa_gt_rrsp_dk "Q20 : contributed more to TFSA - DK"
		label var tfsa_gt_rrsp_r "Q20 : contributed more to RRSP - R"
		label var tfsa_gt_rrsp_other_spec "Q20 : contributed more to TFSA - other specified"

		#delimit ;
		foreach var of varlist rrsp_gt_tfsa_st-rrsp_gt_tfsa_r tfsa_gt_rrsp_st-tfsa_gt_rrsp_r {;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		***********************************
		* Contributions to employer plans *
		***********************************

		 *!!!!! DID NOT DEAL WITH WORK INCOME BRACKETS YET !!!!!

		rename Q22C1_1Definedbenefitpensio emp_db_contr
		rename Q22C1a_1Definedbenefitpensi emp_db_contr_unit
		rename Q22Cb_1Definedbenefitpensio emp_db_contr_freq

		rename Q22C1_2Definedcontributionp emp_dc_contr
		rename Q22C1a_2Definedcontribution emp_dc_contr_unit
		rename Q22Cb_2Definedcontributionp emp_dc_contr_freq


		rename Q22C1_3HybridpensionplanC emp_hybrid_contr
		rename Q22C1a_3Hybridpensionplan emp_hybrid_contr_unit
		rename Q22Cb_3HybridpensionplanF emp_hybrid_contr_freq

		rename Q22C1_4GroupRRSPContributi emp_rrsp_contr
		rename Q22C1a_4GroupRRSPUnit emp_rrsp_contr_unit
		rename Q22Cb_4GroupRRSPFrequency emp_rrsp_contr_freq

		rename Q22C1_5GroupTFSAContributi emp_tfsa_contr
		rename Q22C1a_5GroupTFSAUnit emp_tfsa_contr_unit
		rename Q22Cb_5GroupTFSAFrequency emp_tfsa_contr_freq

		rename Q22C1_6VoluntaryRetirementS emp_vrsp_contr
		rename Q22C1a_6VoluntaryRetirement emp_vrsp_contr_unit
		rename Q22Cb_6VoluntaryRetirementS emp_vrsp_contr_freq

		rename Q22a_1Q22a_1For2017what workinc
		label var workinc "Q22a: Respondent work income for 2017" 



		rename Q22bIsitmorethan60000 workinc_gt_60k
		rename Q22cIsitlessthan80000 workinc_lt_80k
		rename Q22dIsitmorethan100000 workinc_gt_100k
		rename Q22eIsitmorethan40000 workinc_gt_40k
		rename Q22fIsitmorethan20000 workinc_gt_20k


		label var workinc_gt_60k "Q22b : Respondent work income in 2017 is greater than 60K"
		label var workinc_lt_80k "Q22c : Respondent work income in 2017 is less than 80K"
		label var workinc_gt_100k "Q22d : Respondent work income in 2017 is greater than 100K"
		label var workinc_gt_40k "Q22e : Respondent work income in 2017 is greater than 40K"
		label var workinc_gt_20k "Q22f : Respondent work income in 2017 is greater than 20K"

		#delimit ;
		foreach var of varlist workinc_gt_60k workinc_lt_80k workinc_gt_100k workinc_gt_40k workinc_gt_20k {;
			destring `var', replace;
			recode `var' (1=1) (2=0) (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr



		foreach name in "db" "dc" "hybrid" "rrsp" "tfsa"  "vrsp" {
		label var emp_`name'_contr "Q22: contribution to employer `name' in 2017"
		label var emp_`name'_contr_freq "Q22 :  Frequency of contribution to employer `name' in 2017"
		label def emp_`name'_contr_freq 1 "Per week" 2 "Every 2 weeks" 3 "Per month" 4 "Per year"
		label val  emp_`name'_contr_freq emp_`name'_contr_freq


		label var emp_`name'_contr_unit "Q22 :  Unit of contribution to employer `name' for 2017"
		label def emp_`name'_contr_unit 1 "Dollars" 2 "Percent" 
		label val  emp_`name'_contr_unit emp_`name'_contr_unit

		*Created an annual contribution variable to employer plans from contribution amount, unit and frequency
		gen emp_`name'_contr_year = emp_`name'_contr*52 if emp_`name'_contr_freq==1 & emp_`name'_contr_unit ==1
		replace emp_`name'_contr_year  = emp_`name'_contr*26 if emp_`name'_contr_freq==2 & emp_`name'_contr_unit ==1
		replace emp_`name'_contr_year  = emp_`name'_contr*12 if emp_`name'_contr_freq==3 & emp_`name'_contr_unit ==1
		replace emp_`name'_contr_year  = emp_`name'_contr if emp_`name'_contr_freq==4 & emp_`name'_contr_unit ==1
		replace emp_`name'_contr_year  = workinc * (emp_`name'_contr/100) if emp_`name'_contr_unit ==2

		label var emp_`name'_contr_year "Q22: Annual contribution to employer `name' in 2017"

		replace emp_`name'_contr_year =. if emp_`name'_contr_year > workinc


		}

		rename Q23Didafinancialadvisorco advisor_rrsp
		label var advisor_rrsp "Q23: Financial advisor contacted respondent to talk about RRSP in 2018"

		rename Q23aDidheofferyoualoant advisor_rrsp_loan
		label var advisor_rrsp "Q23a: Financial advisor offered an RRSP loan"

		rename Q23bDidyoutakeoutsuchan has_rrsp_loan
		label var has_rrsp_loan "Q23b : respondent took the RRSp loan"

		rename Q24Didafinancialadvisorco  advisor_tfsa
		label var advisor_tfsa "Q23: Financial advisor contacted respondent to talk about TFSA in 2018"

		#delimit ;
		foreach var of varlist advisor_rrsp advisor_rrsp_loan has_rrsp_loan advisor_tfsa {;
			destring `var', replace;
			recode `var' (1=1) (2=0) (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr



		rename Q23c_1Itwillyieldmoremone has_rrsp_loan_return 
		rename Q23c_2Theinterestrateoffer  has_rrsp_loan_interest
		rename Q23c_3Iwantedtomaximizemy has_rrsp_loan_max
		rename Q23c_4Iwasfollowingthefin has_rrsp_loan_advisor
		rename Q23c_5Iwasfollowingtherec has_rrsp_loan_family
		rename Q23c_6OtherenterWhySel has_rrsp_loan_other
		rename Q23c_7777777DontknowWhy has_rrsp_loan_dk
		rename Q23c_8888888Refusetoanswer has_rrsp_loan_r
		rename Q23c_6_otherOtherenterWh has_rrsp_loan_other_spec


		label var has_rrsp_loan_return "Q23c: Has RRSP loan - yield more money than cost of loan"
		label var has_rrsp_loan_interest "Q23c: Has RRSP loan - interest rate is interesting"
		label var has_rrsp_loan_max "Q23c: Has RRSP loan - to maximize RRSP contribution"
		label var has_rrsp_loan_advisor "Q23c: Has RRSP loan - suggested by financial advisor"
		label var has_rrsp_loan_family "Q23c: Has RRSP loan - suggested by someone close"
		label var has_rrsp_loan_other "Q23c: Has RRSP loan - Other"
		label var has_rrsp_loan_other_spec "Q23c: Has RRSP loan - Other specified"
		label var has_rrsp_loan_dk "Q23c: Has RRSP loan - DK"
		label var has_rrsp_loan_r "Q23c: Has RRSP loan - R"

		rename Q23d_1Itwouldhaveyieldedl no_rrsp_loan_return
		rename Q23d_2Theinterestrateoffer no_rrsp_loan_interest
		rename Q23d_3Ididnotwanttoaddt no_rrsp_loan_debt
		rename Q23d_4Iwasfollowingtherec no_rrsp_loan_family
		rename Q23d_5OtherenterWhySel no_rrsp_loan_other
		rename Q23d_7777777DontknowWhy no_rrsp_loan_dk
		rename Q23d_8888888Refusetoanswer no_rrsp_loan_r
		rename Q23d_5_otherOtherenterWh no_rrsp_loan_other_spec

		label var no_rrsp_loan_return "Q23d : No RRSP loan - yield less money than cost of loan"
		label var no_rrsp_loan_interest "Q23d : No RRSP loan - interest rate not interesting"
		label var no_rrsp_loan_debt "Q23d : No RRSP loan - did not want to add to my debt"
		label var no_rrsp_loan_family "Q23d : No RRSP loan - suggested by someone close"
		label var no_rrsp_loan_other "Q23d : No RRSP loan - other"
		label var no_rrsp_loan_dk "Q23d : No RRSP loan - DK"
		label var no_rrsp_loan_r "Q23d : No RRSP loan - R"
		label var no_rrsp_loan_other_spec "Q23d : No RRSP loan - Other specified"


		#delimit ;
		foreach var of varlist has_rrsp_loan_return-has_rrsp_loan_r no_rrsp_loan_return-no_rrsp_loan_r {;
			destring `var', replace;
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr



		rename Q25Atwhatagedoyouplanon retir_age
		label var retir_age "Q25: respondent's retirement age"

		rename Q26Doyouhaveafinancialpl retir_plan
		label var retir_plan "Q26: respondent has a financial plan for retirement"



		#delimit ;
		foreach var of varlist retir_age retir_plan {;
			destring `var', replace;
			recode `var' (1=1) (2=0) (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q27_1Q27_1Intodaysdollar retir_totinc
		label var retir_totinc "Q27 : Respondent total retirement income at 70"

		 
		rename Q27aItismorethan60000 retir_totinc_gt_60k
		rename Q27bIsitlessthan80000 retir_totinc_lt_80k
		rename Q27cIsitmorethan100000 retir_totinc_gt_100k
		rename Q27dIsitmorethan40000 retir_totinc_gt_40k
		rename Q27eIsitmorethan20000 retir_totinc_gt_20k


		label var retir_totinc_gt_60k "Q27a : Respondent total retirement income at 70 is greater than 60K"
		label var retir_totinc_lt_80k "Q27b : Respondent total retirement income at 70 is less than 80K"
		label var retir_totinc_gt_100k "Q27c : Respondent total retirement income at 70 is greater than 100K"
		label var retir_totinc_gt_40k "Q27d : Respondent total retirement income at 70 is greater than 40K"
		label var retir_totinc_gt_20k "Q27e : Respondent total retirement income at 70 is greater than 20K"

		rename Q28_1Q28_1Intodaysdollar retir_totinc_sp
		label var retir_totinc "Q27 : Spouse total retirement income when respondent is 70"

		rename Q28aIsitmorethan60000 retir_totinc_sp_gt_60k
		rename Q28bIsitlessthan80000 retir_totinc_sp_lt_80k
		rename Q28cIsitmorethan100000  retir_totinc_sp_gt_100k
		rename Q28dIsitmorethan40000 retir_totinc_sp_gt_40k
		rename Q28eIsitmorethan20000 retir_totinc_sp_gt_20k


		label var retir_totinc_sp_gt_60k "Q28a : Spouse total retirement income at 70 is greater than 60K"
		label var retir_totinc_sp_lt_80k "Q28b : Spouse total retirement income at 70 is less than 80K"
		label var retir_totinc_sp_gt_100k "Q28c : Spouse total retirement income at 70 is greater than 100K"
		label var retir_totinc_sp_gt_40k "Q28d : Spouse total retirement income at 70 is greater than 40K"
		label var retir_totinc_sp_gt_20k "Q28e : Spouse total retirement income at 70 is greater than 20K"


		#delimit ;
		foreach var of varlist retir_totinc_* {;
			destring `var', replace;
			recode `var' (1=1) (2=0) (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr

		rename Q29_1Iwillretirelaterthan low_retir_later
		rename Q29_2Iwillreducemyspendin low_retir_spend
		rename Q29_3Iwilltakeapartialre low_retir_partial
		rename Q29_4OtherenterIfyourr low_retir_other
		rename Q29_7777777DontknowIfyou low_retir_dk
		rename Q29_8888888Refusetoanswer low_retir_r
		rename Q29_4_otherOtherenterIf low_retir_other_spec

		label var low_retir_later "Q29: if retirement income is lower than expected - retire later"
		label var low_retir_spend "Q29: if retirement income is lower than expected - reduce spending"
		label var low_retir_partial "Q29: if retirement income is lower than expected - partial retirement"
		label var low_retir_other "Q29: if retirement income is lower than expected - other"
		label var low_retir_dk "Q29: if retirement income is lower than expected - DK"
		label var low_retir_r "Q29: if retirement income is lower than expected - R"
		label var low_retir_other_spec "Q29: if retirement income is lower than expected - Other specified"

		#delimit ;
		foreach var of varlist low_retir_later-low_retir_r {;
			destring `var', replace;
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr



		rename Q30Intodaysdollarswhati retir_spend
		label var retir_spend "Q30 : Monthly spending at retirement (around 70)"

		rename Q30aIsitmorethan9000 retir_spend_gt_9k
		rename Q30bIsitlessthan13000 retir_spend_lt_13k
		rename Q30cIsitmorethan11000 retir_spend_gt_11k
		rename Q30dIsitmorethan15000 retir_spend_gt_15k
		rename Q30eIsitlessthan17000 retir_spend_lt_17k
		rename Q30fIsitmorethan5000 retir_spend_gt_5k
		rename Q30gIsitlessthan7000 retir_spend_lt_7k
		rename Q30hIsitlessthan3000 retir_spend_lt_3k
		rename Q30iIsitmorethan1000 retir_spend_gt_1k



		label var retir_spend_gt_9k "Q30a : monthly spending at retirement is greater than 9k"
		label var retir_spend_lt_13k "Q30b : monthly spending at retirement is less than 13k"
		label var retir_spend_gt_11k "Q30c : monthly spending at retirement is greater than 11k"
		label var retir_spend_gt_15k "Q30d : monthly spending at retirement is greater than 15k"
		label var retir_spend_lt_17k "Q30e : monthly spending at retirement is less than 17k"
		label var retir_spend_gt_5k "Q30f : monthly spending at retirement is greater than 5k"
		label var retir_spend_lt_7k "Q30g : monthly spending at retirement is less than 7k"
		label var retir_spend_lt_3k "Q30h : monthly spending at retirement is less than 3k"
		label var retir_spend_gt_1k "Q30i : monthly spending at retirement is greater than 1k"

		#delimit ;
		foreach var of varlist retir_spend_* {;
			destring `var', replace;
			recode `var' (1=1) (2=0) (7777777 =7) (8888888=8);
			label def `var'  1 "Yes" 0 "No" 7 "DK" 8 "R";
			label val `var' `var';
		};
		#delimit cr



		rename Q31Howmuchsavingsdoyouwa retir_savings
		label var retir_savings "Q31: savings respondent want to have for retirement"


		rename Q32Supposeyouhad100ina finlit_interest
		rename Q33Imaginethattheinterest finlit_inflation
		rename Q34Doyouthinkthefollowing  finlit_risk


		#delimit ;
		foreach var of varlist finlit_interest finlit_inflation  finlit_risk{;
			destring `var', replace;
			recode `var' (7777777 =7) (8888888=8);
		#delimit cr
		}

		label var  finlit_interest "Q32 : Financial literacy question - interest rate"
		label def finlit_interest 1 "Correct" 2 "Wrong: exactly" 3 "Wrong: less" 7 "DK" 8 "R"
		label val  finlit_interest finlit_interest

		label var  finlit_inflation "Q33 : Financial literacy question - inflation"
		label def finlit_inflation 1 "Wrong: more" 2 "Wrong: exactly" 3 "Correct" 7 "DK" 8 "R"
		label val  finlit_inflation finlit_inflation


		label var  finlit_risk "Q33 : Financial literacy question - risk and diversification"
		label def finlit_risk 1 "Wrong" 2 "Correct" 7 "DK" 8 "R"
		label val  finlit_risk finlit_risk

		rename Q35_11Forthisquestionwe lottery_t_1
		rename Q35_22Forthisquestionwe lottery_t_2
		rename Q35_33Forthisquestionwe lottery_t_3
		rename Q35_44Forthisquestionwe lottery_t_4
		rename Q35_55Forthisquestionwe lottery_t_5
		rename Q35_66Forthisquestionwe lottery_t_6
		rename Q35_77Forthisquestionwe lottery_t_7
		rename Q35_88Forthisquestionwe lottery_t_8
		rename Q35_99Forthisquestionwe lottery_t_9
		rename Q35_1010Forthisquestion lottery_t_10

		rename Q36_11Forthisquestionwe time_t_1
		rename Q36_22Forthisquestionwe time_t_2
		rename Q36_33Forthisquestionwe time_t_3
		rename Q36_44Forthisquestionwe time_t_4
		rename Q36_55Forthisquestionwe time_t_5
		rename Q36_66Forthisquestionwe time_t_6
		rename Q36_77Forthisquestionwe time_t_7
		rename Q36_88Forthisquestionwe time_t_8
		rename Q36_99Forthisquestionwe time_t_9
		rename Q36_1010Forthisquestion time_t_10

		forvalues i = 1/10 {

		encode lottery_t_`i' , generate(lottery_`i')
		drop lottery_t_`i' 
		label var lottery_`i' "Q35: Lottery question - choice number `i'"

		encode time_t_`i' , generate(time_`i')
		drop time_t_`i' 
		label var time_`i' "Q36: Time preference question - choice number `i'"



		}

		rename  hVideoHIDDENVideoPathAss intervention
		label var intervention "Intervention received"
		destring intervention, replace
		label def intervention 1 "Video + slide" 2 "Video only" 3 "No intervention"
		label val intervention intervention

		rename Q37Accordingtoyouarethe know_deductible
		rename Q38Accordingtoyouwhenmon know_withdaw_tax
		rename Q39MoneyinvestedinanRRSP know_returns_tax
		rename Q40Accordingtoyouisthere know_penalty
		rename Q41Letsassumeyouwithdraw know_room

		label var know_deductible "Q37: RRSP vs TFSA : are contributions deductible"
		label var know_withdaw_tax "Q38: RRSP vs TFSA : are withdrawals taxed in year they are made"
		label var know_returns_tax "Q39: RRSP vs TFSA : are returns taxed in year they are made"
		label var know_penalty "Q40: RRSP vs TFSA : is there penalty if amount withdrawn before retirement"
		label var know_room "Q41: RRSP vs TFSA : are withdrawals added back to contribution room"



		foreach var of varlist know_deductible know_withdaw_tax know_returns_tax know_penalty know_room{

		destring `var', replace
		recode `var' (7777777 =7) (8888888=8)

		}
		label def know_deductible 1 "Correct : RRSP only" 2 "Wrong: TFSA only" 3 "Wrong : both" 4 "Wrong: none" 7 "DK" 8 "R"
		label def know_withdaw_tax 1 "Correct : RRSP only" 2 "Wrong: TFSA only" 3 "Wrong : both" 4 "Wrong: none" 7 "DK" 8 "R"
		label def know_returns_tax 1 "Wrong : RRSP only" 2 "Wrong: TFSA only" 3 "Wrong : both" 4 "Correct: none" 7 "DK" 8 "R"
		label def know_penalty 1 "Wrong : RRSP only" 2 "Wrong: TFSA only" 3 "Wrong : both" 4 "Correct: none" 7 "DK" 8 "R"
		label def know_room 1 "Wrong : RRSP only" 2 "Correct: TFSA only" 3 "Wrong : both" 4 "Wrong: none" 7 "DK" 8 "R"

		foreach var of varlist know_deductible know_withdaw_tax know_returns_tax know_penalty know_room{

		label val  `var' `var'
		}


		forvalues i = 1/6 {
		local j = `i' +41

		rename Q`j'Theamountyouwillwithdr scn_`i'
		destring scn_`i', replace
		recode scn_`i' (7777777 =7) (8888888=8)
		label var scn_`i' "Q`j': scenario `i'"
		label def scn_`i' 1 "RRSP" 2 "TFSA" 7 "DK, soft launch only" 8 "R, soft launch only"
		label val scn_`i' scn_`i'
		}






		save "data\Clean_data.dta", replace

